home *** CD-ROM | disk | FTP | other *** search
/ The 640 MEG Shareware Studio 2 / The 640 Meg Shareware Studio CD-ROM Volume II (Data Express)(1993).ISO / basic / ds40bpds.zip / MENUDEMO.BAS < prev    next >
BASIC Source File  |  1990-07-27  |  1KB  |  42 lines

  1. ' $INCLUDE: 'DOORSORC.INT'
  2. PROGNAME$ = "Menu Demo"   'Set up Door Source status line variables
  3. RELEASE$ = "1.0"
  4. CALL ClrScrn              'Clear the screen and close the config file
  5. CLOSE #1
  6.  
  7. DIM Menu.Selections$(3)
  8.     Menu.Selections$(1) = "1) Play Music and Quit"
  9.     Menu.Selections$(2) = "2) Print your name and Quit"
  10.     Menu.Selections$(3) = "3) Just Quit!"
  11.  
  12. CALL NL(2)
  13. Line.Of.Text$ = "Menu Manager Demo Menu"  ' Center this text and send it
  14. CALL Center(Line.Of.Text$)
  15. CALL Send(Line.Of.Text$, No, Yes, 14)
  16. CALL NL(1)
  17.  
  18. '                      1              2    3  4               4                              5    6
  19. CALL MenuManager(Menu.Selections$(), Yes, 10, 3, "Use + and - to move and Enter to select or type the number", 15, BAR)
  20. ' 1 -=> Menu Selections stored in an array
  21. ' 2 -=> Center everything printed in menu
  22. ' 3 -=> Color of menu selections
  23. ' 4 -=> Tells user how to select an item
  24. ' 5 -=> Color of how to select an item
  25. ' 6 -=> What selection they selected (Returned to you, not sent to it)
  26.  
  27. CALL NL(3) ' Make sure you won't print on top of menu
  28.  
  29. IF BAR = 1 THEN GOTO PlayMusic:
  30. IF BAR = 2 THEN GOTO PrintName:
  31. IF BAR = 3 THEN END
  32. CALL ExitDoor
  33.  
  34. PlayMusic:
  35.  CALL ANSIMusic("ABCDEFG", Yes)
  36.  CALL ExitDoor
  37.  
  38. PrintName:
  39.  CALL Send("Hello " + CallName$, No, Yes, 13)
  40.  CALL ExitDoor
  41.  
  42.